<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta http-equiv="X-UA-Compatible" content="IE=edge">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Document</title>
</head>
<body>
  <script>
    var arr = [1,2,3,4];
    arr.a = 12;
    arr.show = function(){
      alert(this.a);
      // this就是arr本身
      // this是当前发生事件的对象
      // 当前的方法属于谁，this就是谁
    }
    arr.show()
  </script>
</body>
</html>